﻿#pragma once
#ifndef MYTHREAD_H
#define MYTHREAD_H

#include <QObject>
#include <QTcpSocket>

class MyThread:public QObject
{
    Q_OBJECT
public:
    explicit MyThread(QTcpSocket* sock);
    void onConnecting(QString type);
    void handleFileRecv();
    void handleImgRecv();
    void handleAudioRecv();
    void handleVideoRecv();
    void OnSocketStatus(QAbstractSocket::SocketState socketState);
signals:
    void connecting(QString type);//建立sock的readready connect连接
    void connected();
private:
    QTcpSocket* m_psock;
};

#endif // MYTHREAD_H
